Show diffs and pause only if "fc" returns with an error.
authoroliskoli <oliskoli@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Mon, 19 Dec 2005 23:01:30 +0000 (23:01 +0000)
committeroliskoli <oliskoli@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Mon, 19 Dec 2005 23:01:30 +0000 (23:01 +0000)
gpsbabel/mingw/mkwintesto.c

index bfeb7a1c3915c8cb000e0aaa5ef3dc745f620b7f..3b25829d4b7f4ba8098ab3841bf3d817c640cf47 100644 (file)
@@ -151,8 +151,8 @@ int argc,
                        f_outputLine(pfTestoOut, "FOR /f \"delims=\" %%a IN ('fc %PARAM1% %PARAM2%') DO IF \"x%%a\"==\"xFC: no differences encountered\" GOTO :EOF");
                        f_outputLine(pfTestoOut, "REM Show the first 5 lines of difference");
                        f_outputLine(pfTestoOut, "fc %1 /LB5 %PARAM1% %PARAM2%");
-                       f_outputLine(pfTestoOut, "ECHO %* are not the same (first 5 differences above) - pausing. ^C to quit if required");
-                       f_outputLine(pfTestoOut, "PAUSE");
+                       f_outputLine(pfTestoOut, "if errorlevel 1 ECHO %* are not the same (first 5 differences above) - pausing. ^C to quit if required");
+                       f_outputLine(pfTestoOut, "if errorlevel 1 PAUSE");
                        f_outputLine(pfTestoOut, "GOTO :EOF");
                        f_outputLine(pfTestoOut, "");
                        f_outputLine(pfTestoOut, "REM ==================================");